export default [
    {
        // 父请求
        path: '/',
        name: 'Layout',
        component: () => import('../views/LayOut.vue'),
        redirect: '/index',
        // 子请求
        children: [
            {
                path: '/index',// 请求的主页面路径
                name: 'index',
                component: () => import('../views/index/HomeIndex'),// 返回主页面
            },
            {
                path: '/orders/list',// 请求订单列表路径
                name: 'orders_list',
                component: () => import('../views/orders/OrdersList'),// 请求订单列表
                meta: {
                    bread: [
                        { name: '订单管理', url: '/orders' },
                        { name: '订单列表', url: '/orders/list' },
                    ],
                },
            },
            {
                path: '/waybill/list',// 请求的运单列表路径
                name: 'waybill_list',
                component: () => import('../views/waybill/WaybillList'),// 返回运单列表组件
                meta: {
                    bread: [
                        { name: '运单管理', url: '/waybill' },// 一级导航
                        { name: '运单列表', url: '/waybill/list' },// 二级导航
                    ],
                    // 加载后组件被缓存
                    keepAlive: true,
                },
            },
        ],
    },
    {
        path: '/login',// 请求的登录页面路径
        name: 'login',
        component: () => import('../views/LoginVue.vue'),// 返回登录页面
    },
];
